package com.hmall.mapper;

import com.hmall.model.MallOrderItemDetail;
import com.hmall.util.MyMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface MallOrderItemDetailMapper extends MyMapper<MallOrderItemDetail> {

    void deleteByItemId(@Param("itemId") Integer itemId);

    List<MallOrderItemDetail> selectList(@Param("orderItemId") Integer orderItemId);

    List<MallOrderItemDetail> selectByGroupNo(@Param("groupNo") Long groupNo);

    void deleteByGroupNo(@Param("groupNo") Long groupNo);

    List<Long> selectGroupNoListByOrderNo(@Param("orderNo") Long orderNo);

    List<MallOrderItemDetail> selectCheck(@Param("orderNo") Long orderNo);

    int selectCountByOrderItemId(@Param("orderItemId") Integer id);

    List<MallOrderItemDetail> selectByItemId(@Param("item_id") Integer item_id);
}